using System;
using OhioState.AssetManaged;
using OhioState.Math;

namespace OhioState.Graphics.Proxy
{
    /// <summary>
    /// Implementation of a directional light proxy object.
    /// </summary>
    [Serializable()]
    public class DirectionalLightProxy : SharedAsset, ILight
    {
        /// <summary>
        /// Create a directional light with a specified name and
        /// default parameters. The light is oriented in -z direction.
        /// </summary>
        /// <param name="name">The name of a light source.</param>
        public DirectionalLightProxy(String name)
            : base(name)
        {
            ambient = new OSUColor(1, 1, 1, 1);
            diffuse = new OSUColor(1, 1, 1, 1);
            specular = new OSUColor(1, 1, 1, 1);
            position = new Vector4(0, 0, -1, 0);
        }

        private OSUColor ambient;
        private OSUColor diffuse;
        private OSUColor specular;
        private Vector4 position;

        public OSUColor Ambient
        {
            get { return ambient; }
            set { ambient = value; }
        }

        public OSUColor Diffuse
        {
            get { return diffuse; }
            set { diffuse = value; }
        }

        public OSUColor Specular
        {
            get { return specular; }
            set { specular = value; }
        }

        public Vector4 Position
        {
            get { return position; }
            set { position = value; FireUpdateChangedEvent(this); }
        }

        public void Enable(IRenderPanel renderPanel)
        {
        }

        public void Enable(IRenderPanel renderPanel, int lightNumber)
        {
        }

        public void Disable(IRenderPanel renderPanel)
        {
        }
    }
}
